<!--空白弹出页面参考模版-->
{extend name='public/layer_base' /}
{block name='content'}
<section class="content">

    <div class="container-fluid">
        <div class="row">
            <div class="col-md-12">
                <div class="card">

                    <div class="card-header">
                        <h3 class="card-title">{$article.name|default=''}</h3>
                    </div>

                    <div class="card-body table-responsive p-0">
                        <table class="table table-hover table-bordered dataTable text-nowrap">
                            <thead>
                            <tr>
                                <th>ID</th>
                                <th>用户</th>
                                <th>文章</th>
                                <th>点赞状态</th>
                                <th>创建时间</th>
                                <th>操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            {foreach name='data' id='item' key='data_key'}
                            <tr>
                                <td>{$item.id}</td>
                                <td>{$item.user.username|default=''}</td>
                                <td>{$item.article.name|default=''}</td>
                                <td>{$item.vote_status_text}</td>
                                <td>{$item.create_time}</td>
                                <td class="td-do">
                                    <button class="btn btn-danger btn-xs AjaxButton" data-toggle="tooltip" title="删除"
                                            data-id="{$item.id}" data-confirm-title="删除确认"
                                            data-confirm-content='您确定要删除ID为 <span class="text-red">{$item.id}</span> 的数据吗'
                                            data-url="{:url('del')}">
                                        <i class="fas fa-trash-alt"></i>
                                    </button>
                                </td>
                            </tr>
                            {/foreach}
                            </tbody>
                        </table>
                    </div>

                    <!-- 数据列表底部 -->
                    <div class="card-footer">
                        {$page|raw}
                        {include file='public/change_page' /}
                    </div>

                </div>
            </div>
        </div>
    </div>
</section>
{/block}
